<template>
  <div class="qheader">
    <span class="name">
      {{ question.QuestionTypeName }}
    </span>
    <span
      v-if="question.Sequence > 0"
      class="number"
    >
      <span class="cur-number">
        {{ question.Sequence }}
      </span>/ {{ totalNumber }}
    </span>
  </div>
</template>

<script lang="ts">
import Vue from 'vue'
export default Vue.extend({
  props: {
    question: {
      type: Object,
      default: () => ({}),
    },
    totalNumber: {
      type: Number,
      default: 0,
    },
  },
})
</script>

<style lang="scss" scoped>
.qheader {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: $examHeaderInAPP;
  font-size: 32px;
  color: #333;
  position: fixed;
  left: 0;
  right: 0;
  top: 0;
  padding: 0 35px;
  z-index: 10;
  background: #fff;
  /deep/ {
    .has-header & {
      top: $navBarHeight;
    }
  }
}
.cur-number {
  color: $primary-app;
}
</style>
